Add AGENTS.md for AI agent onboarding#2663
Conversation
|
/retest |
|
regarding the flake, I opened an issue on kubvirt/kubevirt kubevirt/kubevirt#17397 |
|
@maiqueb can you take a look? |
ormergi
left a comment
There was a problem hiding this comment.
Thanks for the PR, please see my comments
|
|
||
| Cluster Network Addons Operator (CNAO) is a Kubernetes operator that deploys and manages networking add-on components on Kubernetes and OpenShift clusters. It provides a single `NetworkAddonsConfig` CRD to declaratively manage the lifecycle of multiple network plugins, including upgrades, monitoring, and placement configuration. | ||
|
|
||
| ## Architecture |
| ### Core Components | ||
|
|
||
| - **cmd/manager/** - Operator entry point; sets up the controller-runtime manager, scheme, metrics server, and health probes | ||
| - **pkg/controller/networkaddonsconfig/** - Main reconciliation loop (`networkaddonsconfig_controller.go`) and pod controller for status tracking |
There was a problem hiding this comment.
nit: I would omit the "reconciliation" wording, this is controller-runtime jargon that could confuse the model and increase its potential for slops.
The critical part saying its the NAC controller is already there.
There was a problem hiding this comment.
I'm confused, do you mean MAC controller?
There was a problem hiding this comment.
network-addons-config CRD controller
There was a problem hiding this comment.
Change the wording
| @@ -0,0 +1,175 @@ | |||
| This file provides guidance when working with code in this repository. | |||
|
|
|||
| ## Repository Overview | |||
There was a problem hiding this comment.
I think this part should cover what the repository consist of, for example:
- CNAO operator code
- Fetch and generate installation manifests for each component it manages (via the components.yaml)
- e2e tests
- development/test environment setup
- installation manifests
Please consider removing the NetworkAddonsConfig part its already exist in "How It Works"
There was a problem hiding this comment.
DONE, is that OK now?
| tools/ Build helpers (bumper, manifest-templator, metrics docs) | ||
| cluster/ Local dev cluster management (kubevirtci) | ||
| manifests/ Release manifests for OLM | ||
| templates/ CSV templates |
There was a problem hiding this comment.
CSV templetes is pretty ambiguous, please add more context at least saying these are manifests for deploying the project with Operator-Lifecycle-Manager
|
|
||
| - **Go version**: 1.25 (max allowed; auto-installed to `build/_output/bin/go/` via `hack/install-go.sh`) | ||
| - **Build flags**: `GOFLAGS=-mod=vendor GO111MODULE=on CGO_ENABLED=0` | ||
| - **Linting**: golangci-lint v2 with 30+ linters (see `.golangci.yml`) |
There was a problem hiding this comment.
Linters are not actual part of the build toolchain, and its external tool (outside Go binary). Please consider removing this part.
Provides project structure, build/test commands, Go conventions, and development workflow context for AI coding agents. Assisted-by: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Ram Lavi <ralavi@redhat.com>
|
| ### Core Components | ||
|
|
||
| - **cmd/manager/** - Operator entry point; sets up the controller-runtime manager, scheme, metrics server, and health probes | ||
| - **pkg/controller/networkaddonsconfig/** - Main controller loop (`networkaddonsconfig_controller.go`) and pod controller for status tracking |
There was a problem hiding this comment.
nit:
How about:
| - **pkg/controller/networkaddonsconfig/** - Main controller loop (`networkaddonsconfig_controller.go`) and pod controller for status tracking | |
| - **pkg/controller/networkaddonsconfig/** - NetworkAddonsConfig resource controller. The project main controller. |
|
/lgtm |
|
/approve |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: RamLavi The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |



What this PR does / why we need it:
This PR adds an AGENTS.md to the repo
This provides project structure, build/test commands, Go conventions, and development workflow context for AI coding agents.
Special notes for your reviewer:
Release note: